<%@ page pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<jsp:include page="../../common/assets_header.jsp"/>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<script>
jQuery(document).ready(function() {    
	
});

function back(){
	$("#user_form").attr("action","<%=request.getContextPath()%>/base/linkman/list");
	$("#user_form").submit();
}

</script>

</head>
<body >
<!-- content -->	
		<div class="page-content">
			<div class="page-header">
				<h1>
					<c:if test="${baseCompanyLinkman.baseCompanyLinkmanId==null }">新增联系人</c:if>
        			<c:if test="${baseCompanyLinkman.baseCompanyLinkmanId!=null }">编辑联系人</c:if>
					<small>
						<i class="icon-double-angle-right"></i>
					</small>
				</h1>
			</div>
				<!-- END PAGE HEADER-->
				<div class="row">
					<c:if test="${success}">
						<div class="alert alert-success">
							<button class="close" data-dismiss="alert"></button>
							<strong><spring:message code="success"></spring:message>!</strong> <spring:message code="save success"></spring:message>！
						</div>
					</c:if>
					
					<c:if test="${success==false}">
						<div class="alert alert-failure">
							<button class="close" data-dismiss="alert"></button>
							<strong><spring:message code="failure"></spring:message>!</strong> ${message}
						</div>
					</c:if>
										
				<div class="col-xs-12">
					<form id="user_form" 
						action="<c:if test="${baseCompanyLinkman.baseCompanyLinkmanId==null}">add</c:if>
						<c:if test="${baseCompanyLinkman.baseCompanyLinkmanId!=null}">edit</c:if>" method="post" class="form-horizontal">
						<input type="hidden" name="sorting_column_order" id="sorting_column_order" value="${sorting_column_order }"/>
						<input type="hidden" name="sorting_asc_desc"  id="sorting_asc_desc" value="${sorting_asc_desc}"/>
						<input type="hidden" name="searchValue"  value="${baseCompanyLinkman}"/>
						<input type="hidden" name="baseCompanyLinkmanId" value="${baseCompanyLinkman.baseCompanyLinkmanId}"></input>
						<input type="hidden" name="token" value="${token}"></input>
						<input type="hidden" name="iDisplayStart" value="${iDisplayStart}">
						<div class="form-group">
								<label class="col-sm-5 control-label no-padding-right" for="form-field-1">公司编号：</label>
								<div class="controls">
									<input type="text" maxlength="30" name="companyCode" value="${baseCompanyLinkman.companyCode }" class="m-wrap" />
									<span class="help-inline"></span>
								</div>
							</div>
							
						<div class="form-group">
							<label class="col-sm-5 control-label no-padding-right" for="form-field-1">名字：</label>
							<div class="controls">
								<input type="text" maxlength="30" name="firstName" value="${baseCompanyLinkman.firstName}"  class="m-wrap" />
								<span class="help-inline"></span>
							</div>
						</div>
						
						<div class="form-group">
							<label class="col-sm-5 control-label no-padding-right" for="form-field-1">姓氏：</label>
							<div class="controls">
								<input type="text" maxlength="30" name="lastName" value="${baseCompanyLinkman.lastName}"  class="m-wrap" />
								<span class="help-inline"></span>
							</div>
						</div>
						
						<div class="form-group">
							<label class="col-sm-5 control-label no-padding-right" for="form-field-1">地址：</label>
							<div class="controls">
								<input type="text" maxlength="30" name="address" value="${baseCompanyLinkman.address}"  class="m-wrap" />
								<span class="help-inline"></span>
							</div>
						</div>
						
						<div class="form-group">
							<label class="col-sm-5 control-label no-padding-right" for="form-field-1">手机：</label>
							<div class="controls">
								<input type="text" maxlength="30" name="mobile" value="${baseCompanyLinkman.mobile}"  class="m-wrap" />
								<span class="help-inline"></span>
							</div>
						</div>
						
						<div class="form-group">
							<label class="col-sm-5 control-label no-padding-right" for="form-field-1">座机：</label>
							<div class="controls">
								<input type="text" maxlength="30" name="telephone" value="${baseCompanyLinkman.telephone}"  class="m-wrap" />
								<span class="help-inline"></span>
							</div>
						</div>
						
						<div class="form-group">
							<label class="col-sm-5 control-label no-padding-right" for="form-field-1">电子邮箱：</label>
							<div class="controls">
								<input type="text" maxlength="30" name="email" value="${baseCompanyLinkman.email}"  class="m-wrap" />
								<span class="help-inline"></span>
							</div>
						</div>
						
						<div class="form-group">
							<label class="col-sm-5 control-label no-padding-right" for="form-field-1">传真：</label>
							<div class="controls">
								<input type="text" maxlength="30" name="fax" value="${baseCompanyLinkman.fax}"  class="m-wrap" />
								<span class="help-inline"></span>
							</div>
						</div>
						<div class="form-actions center">
							<button type="submit" class="btn btn-xs btn-primary"><spring:message code="btn.common.save"></spring:message></button>
							<button type="button" onclick="back();" class="btn btn-xs btn-primary"><spring:message code="btn.common.back"></spring:message></button>
						</div>
						
					</form>
				</div>
			</div>
		</div>
		<!-- content end -->
</body>
